package com.ftg.learn.lesson3;

import java.util.Scanner;

/**
 * 学习流程2
 *
 * @author kangjx
 * @version 1.0
 * @date 2023/6/5 下午2:28
 */
public class Flow02 {

    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        System.out.println("请输入一个整数");
        int a = s.nextInt();
        if (a % 2 == 0) {
            if (a % 4 == 0) {
                System.out.println("星期4");
            } else if (a % 3 == 0) {
                System.out.println("星期3");
            } else {
                System.out.println("星期2");
            }
        }

        if (a % 3 == 0) {
            if (a % 4 == 0) {
                System.out.println("星期4");
            } else if (a % 5 == 0) {
                System.out.println("星期3");
            } else {
                System.out.println("星期2");
            }
        }

        //并列 if(){} if(){}
        //嵌套 if(){ if(){} }
        //一组 if(){}else if(){}else if(){}.....else{}


        //三目运算符 x?y:z

        int t = s.nextInt();

        if (t < 60) {
            System.out.println("不及格");
        } else if (t < 70) {
            System.out.println("及格");
        } else if (t < 80) {
            System.out.println("中");
        } else if (t < 90) {
            System.out.println("优");
        } else {
            System.out.println("优+");
        }

        s.close();
    }

}
